package com.woniuxy.system.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.woniuxy.system.demol.entity.Role;
import com.woniuxy.system.demol.entity.SystemUserUpdate;
import com.woniuxy.system.demol.entity.User;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.woniuxy.system.demol.vo.SpeUserVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author why
 * @since 2023-09-08
 */
@Mapper
public interface UserMapper extends BaseMapper<User> {
     List<User> findAll2(@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);
    User findAll(String account);

    int pageListCount();

    String findByToken(String token);

    Integer findByAccount(String name);
    User findByAcc(String name);

    User findByUId(Integer id1);

    List<Role> findBySid(int newSid);

    int pageListCount3();
    int pageListCount4();

    List<User> findAll3(@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);

    List<User> findAll4(@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);

    List<User> searchAll(@Param("input") String input, @Param("offset") Integer offset, @Param("pageSize") Integer pageSize);

    List<User> searchAll2(@Param("num")Integer num,@Param("input") String input, @Param("offset") Integer offset, @Param("pageSize") Integer pageSize);

    int pageListCount1(@Param("input") String input, @Param("offset") Integer offset, @Param("pageSize") Integer pageSize);

    int pageListCount2(@Param("num")Integer num,@Param("input") String input, @Param("offset") Integer offset, @Param("pageSize") Integer pageSize);

    List<SystemUserUpdate> searchHistory(String account);

    List<SpeUserVo> selectSpeUser(@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);

    List<SpeUserVo> selectSpeUserBySid(@Param("offset") Integer offset, @Param("pageSize") Integer pageSize,@Param("sid")String sid);

    int pageListCount7(String sid);

    String fundPassword(String account);
}
